interface UseFormOption<T extends Object> {
  defaultFormData: T
}

function useForm<T extends Object>(option: UseFormOption<T>) {
  const formData = reactive(option.defaultFormData)

  return {
    formData: toRefs(formData)
  }
}

export default useForm
